W15 <<
Previous Next >> inverse kinematic 逆向運動學
forward kinematics 正向運動學
x,y with respect to the world coordinate frame.
x和y為y座標框架
the problem here is that given x and y,we want to determine the joined angles,q1and q2
以x為基準到a1一個角度q1,以a1為基準到a2一個角度q2
The solution that we're going to follow in this particular section is a geometric.
解決部分幾何
一
利用畢氏定理(pythagoras theorem)畢達哥拉斯定理
我們可以知道原點到e點的距離為r
利用餘弦公式(所有邊都標記為A, B, C,角都標記為a, b, c )
A*A=B*B+C*C-2BCcosa
r*r=a1*a1+a2*a2-2a1a2cos(alpha)
經過移項

180-q2=alpha
cosq2=-cos(alpha)
把餘弦公式套用到q2的三角形
我們知道q2所以鄰邊為a2cosq2對邊為a2sinq2
可以用q2角寫出正弦關係
現在把原點連到E點畫出的角度為BETA,邊常用藍色表示
藍色底邊為a1+a2cosq2
回到之前化的紅色三角形我們可以建立出q1和beta的關係
設q1+beta=gamma
總結
我們有q2餘弦方程式和q1方程式
餘弦函數在0對稱
所以我們知道cosq2的值可能為正或負
我們選擇正角才可以寫出這式子
現在我們來用逆向運動學來處理雙連桿機構
W15 <<
Previous Next >> inverse kinematic 逆向運動學